local skel = fk.CreateSkill {
  name = "emo__xingcun",
  tags = {Skill.Compulsory}
}

Fk:loadTranslationTable{
  ["emo__xingcun"] = "幸存",
  [":emo__xingcun"] = "锁定技，当其他角色死亡后，你将回复体力至体力上限，若你未受伤则改为摸三张牌。",

  ["$emo__xingcun1"] = "果然，大家都会抛下夏洛死去……",
  ["$emo__xingcun2"] = "说了会回来，但最终没有任何人做到",
}

skel:addEffect(fk.Deathed, {
  anim_type = "defensive",
  can_trigger = function(self, event, target, player, data)
    return target ~= player and player:hasSkill(skel.name)
  end,
  on_use = function(self, event, target, player, data)
    if player:isWounded() then
      player.room:recover { num = player.maxHp - player.hp, skillName = self.name, who = player, recoverBy = player }
    else
      player:drawCards(3, self.name)
    end
  end,
})

return skel
